package com.camelgreen.sys.service;

import java.util.List;


import org.springframework.stereotype.Component;

import com.camelgreen.baseclass.BaseManager;
import com.camelgreen.baseclass.EntityDao;
import com.camelgreen.page.Page;
import com.camelgreen.page.PageParameter;
import com.camelgreen.sys.dao.UserDao;
import com.camelgreen.sys.model.User;

@Component
public class UserManager extends BaseManager<User, String>{
	
	private UserDao userDao;
	//增加setXXXX()方法,spring就可以通过autowire自动设置对象属性
	public void setUserDao(UserDao userDao) {
		this.userDao = userDao;
	}

	@Override
	protected EntityDao getEntityDao() {		
		return this.userDao;
	}

	public Page findByPageRequest(PageParameter pr) {
		return userDao.findByPageRequest(pr);
	}
	
}
